package samples.chapter08;

import org.springframework.web.bind.annotation.*;

@RequestMapping("/chapter08")
@RestController
public class Chapter08HelloController {
    @GetMapping("/hello")
    public String hello(String name) {
        return "Hello " + name + " !";
    }

    @PostMapping("/book")
    public String book(@RequestBody Chapter08Book book) {
        return book.toString();
    }
}
